package cn.itlaobing.eshop.web.dao;

import cn.itlaobing.eshop.web.entity.FoucssEntity;
import org.apache.commons.dbutils.QueryRunner;
import org.apache.commons.dbutils.handlers.BeanListHandler;

import java.sql.SQLException;
import java.util.List;

/**
 * Created by IT-XuGeek on 2017/11/15.
 */
public class FocussDao extends BaseDao{
    public List<FoucssEntity> photo()throws SQLException {
        String sql= "SELECT img FROM itlb_focuss" ;
        QueryRunner qr=new QueryRunner(getDataSource());
        BeanListHandler<FoucssEntity> beanListHandler=new BeanListHandler<FoucssEntity>(FoucssEntity.class);
        return  qr.query(sql,beanListHandler);

    }
}
